package com.th.supcom.pds.impl.manager.impl;

import java.util.List;
import java.util.Map;

import net.carefx.fc.framework.db.manager.GetSequenceHelper;

import org.apache.ibatis.session.RowBounds;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.th.supcom.pds.domain.pojo.PhamDispensaryConfig;
import com.th.supcom.pds.impl.dao.PhamDispensaryConfigMapper;
import com.th.supcom.pds.impl.manager.PhamDispensaryConfigManager;

/**
 * PhamDispensaryConfig 管理接口实现.
 * 
 * 药房属性.
 */
public class PhamDispensaryConfigManagerImpl implements PhamDispensaryConfigManager
{
    public static final String TAB_PHAM_DISPENSARY_CONFIG = "PHAM_DISPENSARY_CONFIG";

    private PhamDispensaryConfigMapper m_phamDispensaryConfigMapper;

    /** 序列生成器. */
    private GetSequenceHelper m_getSequenceHelper;

    /**
     * 默认的构造函数.
     */
    public PhamDispensaryConfigManagerImpl ()
    {

    }

    /**
     * 获取PhamDispensaryConfigMapper.
     * 
     * @return PhamDispensaryConfigMapper.
     */
    public PhamDispensaryConfigMapper getPhamDispensaryConfigMapper ()
    {
        return m_phamDispensaryConfigMapper;
    }

    /**
     * 注入PhamDispensaryConfigMapper.
     * 
     * @param phamDispensaryConfigMapper set phamDispensaryConfigMapper.
     */
    public void setPhamDispensaryConfigMapper (PhamDispensaryConfigMapper phamDispensaryConfigMapper)
    {
        m_phamDispensaryConfigMapper = phamDispensaryConfigMapper;
    }

    /**
     * 获取序列.
     * 
     * @return GetSequenceHelper
     */
    public GetSequenceHelper getGetSequenceHelper ()
    {
        return m_getSequenceHelper;
    }

    /**
     * 注入序列.
     * 
     * @param getSequenceHelper getSequenceHelper.
     */
    public void setGetSequenceHelper (GetSequenceHelper getSequenceHelper)
    {
        m_getSequenceHelper = getSequenceHelper;
    }

    @Override
    public PhamDispensaryConfig getPhamDispensaryConfigByID (Long id)
    {
        return m_phamDispensaryConfigMapper.getPhamDispensaryConfigByID (id);
    }

    @Override
    public Long getPhamDispensaryConfigSeq ()
    {
        return m_getSequenceHelper.getNextSequenceId (TAB_PHAM_DISPENSARY_CONFIG);
    }

    @Override
    public List <PhamDispensaryConfig> findPhamDispensaryConfigListByExample (PhamDispensaryConfig phamDispensaryConfig)
    {
        return m_phamDispensaryConfigMapper.findPhamDispensaryConfigListByExample (phamDispensaryConfig);
    }

    @Override
    public int findPhamDispensaryConfigCountByExample (PhamDispensaryConfig phamDispensaryConfig)
    {
        return m_phamDispensaryConfigMapper.findPhamDispensaryConfigCountByExample (phamDispensaryConfig);
    }

    @Override
    public List <PhamDispensaryConfig> findPhamDispensaryConfigListByMap (Map <String, Object> params)
    {
        return m_phamDispensaryConfigMapper.findPhamDispensaryConfigListByMap (params);
    }

    @Override
    public List <PhamDispensaryConfig> findPhamDispensaryConfigPagingByMap (Map <String, Object> params, Integer offset, Integer limit)
    {
        return m_phamDispensaryConfigMapper.findPhamDispensaryConfigPagingByMap (new RowBounds (offset, limit), params);
    }

    @Override
    public Integer findPhamDispensaryConfigCountByMap (Map <String, Object> params)
    {
        return m_phamDispensaryConfigMapper.findPhamDispensaryConfigCountByMap (params);
    }

    @Override
    public int modifyPhamDispensaryConfig (PhamDispensaryConfig phamDispensaryConfig)
    {
        return m_phamDispensaryConfigMapper.modifyPhamDispensaryConfig (phamDispensaryConfig);
    }

    @Override
    public int modifyPhamDispensaryConfigByExample (PhamDispensaryConfig phamDispensaryConfig)
    {
        return m_phamDispensaryConfigMapper.modifyPhamDispensaryConfigByExample (phamDispensaryConfig);
    }

    @Override
    public int removePhamDispensaryConfigByID (Long id)
    {
        return m_phamDispensaryConfigMapper.removePhamDispensaryConfigByID (id);
    }

    @Override
    public int removePhamDispensaryConfigByMap (Map <String, Object> params)
    {
        return m_phamDispensaryConfigMapper.removePhamDispensaryConfigByMap (params);
    }

    @Override
    public void addPhamDispensaryConfig (PhamDispensaryConfig phamDispensaryConfig)
    {
        phamDispensaryConfig.setPhamDispensaryConfigId (getPhamDispensaryConfigSeq ());
        m_phamDispensaryConfigMapper.addPhamDispensaryConfig (phamDispensaryConfig);
    }

    /** 日志记录器. */
    public static final Logger s_logger = LoggerFactory.getLogger (PhamDispensaryConfigManagerImpl.class);

    /** 公司版权信息. */
    public static final String copyright = "Copyright 2014, TH Supcom Corporation";

    /** 提交路径. */
    public static final String SCC_BRANCH = "$URL$";

    /** 提交日期. */
    public static final String SCC_LAST_MODIFICATION_DATE = "$Date$";

    /** 最终修改人员. */
    public static final String SCC_LAST_MODIFIER_NAME = "$Author$";

    /** 最终版本号. */
    public static final String SCC_REVISION = "$Revision$";
}